#!/bin/bash
BASEDIR=$(dirname "$0")
cd $BASEDIR/..

# wine-msvc安装参考
# https://github.com/mstorsjo/msvc-wine
# 编译卡住的时候用wineserver -k 重启wine

export XMAKE_GLOBALDIR=$(pwd)

export PATH=/home/yangwang/msvc-wine/msvc/bin/x64:$PATH
xmake g --network=private
xmake f --toolchain=msvc-wine -p windows -a x64 \
    -y \
    -vD \
    --USING_8030USB=n \
    -m releasedbg
xmake project -k compile_commands
xmake -vD -w
xmake install -o install
